from sqlobject import *

class Amostra(SQLObject):
    nome = StringCol(length=50, notNull=1)
    tipo_amostra_id = ForeignKey('TipoAmostra', cascade=False)
    container_id = ForeignKey('Container', cascade=False)
    volume_id = ForeignKey('Volume', notNull=0,
                        default=None, cascade=False)
    peso_id = ForeignKey('Peso', notNull=0,
                      default=None, cascade=False)
    concentracao_id = ForeignKey('Concentracao', notNull=0,
                              default=None, cascade=False)
    volume = DecimalCol(size=9, precision=3, notNull=0, default=None)
    peso = DecimalCol(size=9, precision=3, notNull=0, default=None)
    concentracao = DecimalCol(size=9, precision=3, notNull=0, default=None)
